<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<div class="box category">
					<div class="box-heading">品牌列表</div>
					<div class="box-content">
						<div class="box-category">
							<div class="box-category">
								<ul>
									<c:forEach var="category" items="${categoryList}" varStatus="status">
									        <li class="cat-header">
									        <a class="idCatSubcat"
											href="product/listProduct.html?categoryId=${category.categoryId}">
											<c:out value="${category.categoryName}" />
											</a>
											</li>
									</c:forEach>
								</ul>
							</div>
						</div>
					</div>
				</div>
				<script type="text/javascript">
$(document).ready(function(){
$(function(){
$('.box-product-2  li ').last().addClass('last');
});
}); 
</script>
				<script type="text/javascript">
		(function($){$.fn.equalHeights=function(minHeight,maxHeight){tallest=(minHeight)?minHeight:0;this.each(function(){if($(this).height()>tallest){tallest=$(this).height()}});if((maxHeight)&&tallest>maxHeight)tallest=maxHeight;return this.each(function(){$(this).height(tallest)})}})(jQuery)
	$(window).load(function(){
		if($(".maxheight-best").length){
		$(".maxheight-best").equalHeights()}
	})
</script>
				<div class="box  bestsellers">
					<div class="box-heading">热卖商品</div>
					<div class="box-content">
						<div class="box-product-2">
							<ul>
							 <c:forEach var="bestProduct" items="${featuredProductList}" varStatus="status">
							    <c:if test="${status.count<=5}">
								<c:choose>
							      <c:when test="${status.count==fn:length(featuredProductList)}">
							      <li class="last-in-line">
							      </c:when>
							      <c:otherwise>
										<li>
							      </c:otherwise>
							   </c:choose>
									<div class="image">
										<a href="product/productDetail.html?productId=${bestProduct.productId}"><img
											src="image_upload/${bestProduct.bestBuyImage.path}"
											alt="Acicte magna ipsum dolor">
										</a>
									</div>
									<div class="extra-wrap">
										<div style="height: auto;" class="name">
											<a href="product/productDetail.html?productId=${bestProduct.productId}">
													${bestProduct.productName}</a>
										</div>
										<div class="price">
											<span class="price-new">¥ ${bestProduct.discountPrice}</span><span class="price-old">¥ ${bestProduct.globalprice}</span>
										</div>
									</div>
								</li>
								</c:if>
							  </c:forEach>
							</ul>
						</div>
					</div>
				</div>